package cn.keduox.entity;

import cn.keduox.annotation.*;

import java.io.Serializable;
import java.math.BigDecimal;
import java.sql.Timestamp;

/**
 * 书本版本信息类
 */
@Table(name = "book_version")
public class BookVersion implements Serializable{
    @Id(name = "id")
    @Column(name = "id")
    @Key(farther = "book_version")
    private String id;
    /**
     * isbn首字母必须小写
     */
    @Column(name = "ISBN")
    private String isbn;

    @Column(name = "code")
    private String code;
    /**
     * 书的装帧类型
     */
    @Column(name = "binding_id")
    private String bindingId;

    @Column(name = "pages")
    private Integer pages;
    /**
     * 重量
     */
    @Column(name = "weight")
    private BigDecimal weight;

    @Column(name = "print_time")
    private Integer printTime;

    @Column(name = "create_by")
    private String createBy;
    @Column(name = "create_time")
    private Timestamp createTime;
    @Column(name = "update_by")
    private String  updateBy;
    @Column(name = "update_time")
    private Timestamp updateTime;
    @Column(name = "del_flag")
    private Integer delFlag;
    /**
     * 书籍外键
     */
    @Column(name = "book_id")
    private String bookId;

    /**
     * 书的装帧类型
     */
    @Entity(table = "book_binding",field = "bindingId",address = "cn.keduox.entity.BookBinding",name = "bookBinding")
    private BookBinding bookBinding;


    public BigDecimal getWeight() {
        return weight;
    }


    public BookBinding getBookBinding() {
        return bookBinding;
    }

    public void setBookBinding(BookBinding bookBinding) {
        this.bookBinding = bookBinding;
    }


    public BookVersion() {
    }

    public String getBookId() {
        return bookId;
    }

    public void setBookId(String bookId) {
        this.bookId = bookId;
    }

    public String getIsbn() {
        return isbn;
    }

    public void setIsbn(String isbn) {
        this.isbn = isbn;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }


    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getBindingId() {
        return bindingId;
    }

    public void setBindingId(String bindingId) {
        this.bindingId = bindingId;
    }

    public Integer getPages() {
        return pages;
    }

    public void setPages(Integer pages) {
        this.pages = pages;
    }

    public void setWeight(BigDecimal weight) {
        this.weight = weight;
    }


    public Integer getPrintTime() {
        return printTime;
    }

    public void setPrintTime(Integer printTime) {
        this.printTime = printTime;
    }


    public String getCreateBy() {
        return createBy;
    }

    public void setCreateBy(String createBy) {
        this.createBy = createBy;
    }

    public Timestamp getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }

    public String getUpdateBy() {
        return updateBy;
    }

    public void setUpdateBy(String updateBy) {
        this.updateBy = updateBy;
    }

    public Timestamp getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Timestamp updateTime) {
        this.updateTime = updateTime;
    }

    public Integer getDelFlag() {
        return delFlag;
    }

    public void setDelFlag(Integer delFlag) {
        this.delFlag = delFlag;
    }
}
